﻿
<script type="text/javascript" src="http://api.map.baidu.com/api?v=2.0&ak=XjOymLQ7XokpmPICKh0xlSyw"></script>
<!--加载鼠标绘制工具-->
<script type="text/javascript" src="http://api.map.baidu.com/library/DrawingManager/1.4/src/DrawingManager_min.js"></script>
<link rel="stylesheet" href="http://api.map.baidu.com/library/DrawingManager/1.4/src/DrawingManager_min.css" />
<script type="text/javascript" src="~/Scripts/project/MonitorCenterMap.js"></script>
<link type="text/css" href="~/Content/themes/project/loading.css" rel="stylesheet"/>
<link type="text/css" href="~/Content/themes/spliter/spliter.css" rel="stylesheet"/>
<script type="text/javascript" src="~/Scripts/splitter.js"></script>
<link rel="Stylesheet" href="~/Content/themes/autocomplete/jquery.autocomplete.css"/>
<script type="text/javascript" src="~/Scripts/jquery.autocomplete.js"></script>
<link rel="stylesheet" href="~/Scripts/jquery-easyui/themes/default/easyui.css" />
<script type="text/javascript" src="~/Scripts/jquery-easyui/jquery.easyui.min.js"></script>

<script type="text/javascript" src="~/Scripts/jquery-cluetip/jquery.cluetip.js"></script>
<link rel="stylesheet" href="~/Scripts/jquery-cluetip/jquery.cluetip.css" />

<div id="MonitorCenterDiv" class="fillparentheight MonitorFlexBox-H MonitorFlex-1">
    <div id="MonitorCenterTreeDiv" class="MonitorFlexBox-V">
        @Html.Partial("~/Views/MonitorCenter/Tree.cshtml")
    </div>
    <div id="MonitorCenterDivisionDiv"></div>
    <div id="MonitorCenterContentDiv" class="MonitorFlexBox-H MonitorFlex-1">
        <div id="MonitorMapWaitingDiv">
            @Html.Partial("~/Views/MonitorCenter/Loading.cshtml")
        </div>
        <div id="MonitorMapContentDiv" class="MonitorFlexBox-V MonitorFlex-1">
            @Html.Partial("~/Views/MonitorCenter/Map.cshtml")
        </div>
    </div>
</div>
<script type="text/javascript">
    $(document).ready(function () {
        //$("#MonitorMapWaitingDiv").height($("#MonitorCenterTreeDiv").height());
        //$("#MonitorMapWaitingDiv").width($("#MonitorMapContentDiv").width()-9);
        //$("#MonitorMapContentDiv").height($("#MonitorCenterTreeDiv").height());
        
        //显示等待div
        $("#MonitorMapWaitingDiv").show();
        //初始化百度地图
        InitBaiduMap("武汉市", 14, "MapDiv", true);
        //隐藏或者显示树形
        $("#MonitorCenterDivisionDiv").click(function () {
            $("#MonitorCenterTreeDiv").toggle(500, function () {
                $("#GpsTable").datagrid("resize", {
                    width: function () { return $("#GpsDiv").width(); },
                    height: function () { return $("#GpsDiv").height(); }
                })
            });
            if ($("#MonitorCenterDivisionDiv").hasClass("DivisionMarginLeft")) {
                $("#MonitorCenterDivisionDiv").removeClass("DivisionMarginLeft");
            }
            else {
                $("#MonitorCenterDivisionDiv").addClass("DivisionMarginLeft");
            }
        });

        setTimeout(function () {
            $("#MonitorMapWaitingDiv").hide();
        }, 3000);
        
    });

</script>
